<template>
  <div >
    
  <div class="activityList-box" >
    <div class="activityList">
        <ul> 
          <li @click="toMyActivityDetail(myActivity)" v-for="(myActivity, index) in myActivityList" :key="index">
            <a href="javascript:void(0)"> 
              <p class="title">{{myActivity.title}}</p>
              <p class="date">{{myActivity.id}}</p>
              <p class="date">{{myActivity.name}}</p>
            </a>
          </li>
        </ul>
    </div>
  </div> 

  </div>
</template>

<script>
import request from '../../utils/request'
 
  export default{
    data(){
      return {
        myActivityList:[]
      }
    },  
    async mounted() {
      let data = wx.getStorageSync('user');
      let data1 = data.sno
      console.log(data1)

      let result = await request('/apply/mylist',{data1},'GET');
      console.log(result)
      this.myActivityList = result
    },  
    methods: {
      
      toMyActivityDetail(myActivity){
        wx.navigateTo({
          url:'/pages/myActivityDetail/main?myActivity='+ JSON.stringify(myActivity)
        })
      },
      
    },
  }
</script>

<style scoped>

.activityList-box{
  width: 100%;
}

.activityList-box .activityList{
  width: 85%;
  margin:auto ;
}

.activityList-box .activityList ul li{
  margin-top: 23px;
  background: rgb(219, 145, 145);
  box-shadow: -10px 10px rgb(148, 143, 143);
  opacity: .7;
  border-radius: 10px;
}

.activityList-box .activityList ul li .title{
  font-size: 22px;

}

.activityList-box .activityList ul li .date{
  font-size: 17px;
  margin-top:7px
  
}

</style>
